package com.wwc.sc.service;

import com.wwc.sc.entities.Payment;
import com.wwc.sc.entities.result.CommonResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.concurrent.TimeUnit;

/**
 * @author WWC
 */
@Component
@FeignClient(value = "SPRING-CLOUD-PROVIDER-EUREKA-PAYMENT")
public interface PaymentFeignService {

    @RequestMapping(value = "/payment/getPaymentById/{id}")
    public CommonResult<Payment> getPaymentById(@PathVariable("id") Long id);

    @RequestMapping(value = "/payment/feign/timeout")
    public String paymentFeignTimeOut();



}
